/*
 * @Author: Turump 
 * @Date: 2021-04-12 15:04:42 
 * @Last Modified by: Turump
 * @Last Modified time: 2021-09-17 11:07:50
 */

const { ccclass, property, menu } = cc._decorator;

@ccclass
@menu("按钮/隐私政策")
export default class Privacy extends cc.Component {

    @property()
    iosUrl = ""

    @property()
    androidUrl = ""

    start() {
        this.node.on(cc.Node.EventType.TOUCH_END, this.touchEnd, this)
    }

    touchEnd() {
        let url = this.iosUrl
        if (cc.sys.os == cc.sys.OS_ANDROID) {
            url = this.androidUrl
        }
        cc.sys.openURL(url);
    }

}
